The present invention is directed to a system and method for dynamic image file size manipulation in order to meet specified size limitations. The present invention utilizes image segmentation to produce a mixed raster content (MRC) image with constant foreground layers representing black/white (B/W) text or line art or graphics. Furthermore, the MRC image size may be dynamically controlled so as not to exceed a particular size so as to assure that the image does not exceed network bandwidth, storage or similar capacity constraints.
MRC (Mixed Raster Content) is a powerful image representation concept in achieving high compression ratios while maintaining high reconstructed image quality. MRC has also been established as a compression standard. Within MRC, a basic three-layer (plane) model (contone foreground, contone background, and binary mask) is the most common representation form. It represents a color raster image using a background layer and a mask and foreground layer pair. The foreground and background layers are normally contone bitmaps, while the mask is usually binary. The Mask layer describes how to reconstruct the final images from the other two layers. When the Mask layer pixel value is 1, the corresponding pixel from the Foreground layer is selected for the final image; when it is 0, the corresponding pixel from the Background layer is selected. Each layer may be compressed individually by a suitable compression process. For contone image layers, JPEG is often employed, wherein the Q-factor of the compression is varied in order to achieve better compression ratios at the risk of image quality.
Digital image file size has been an important consideration for users when dealing with the storage and transmission of such files, and more particularly with the introduction of multifunction machines that enable a scan-to-export feature that can, with the touch of a button, scan an image and transfer it to a predetermined destination. More specifically, scanning color documents to networks is becoming a standard feature on many devices. High quality, scanned documents are increasingly used in many applications and the storage/network requirements for these documents are large. In some instances, mixed raster content output is being offered as a selection in the scan-to-export selection of digital multifunction devices to reduce the file size. Using MRC, the document is first analyzed and two layers are extracted—a text/mask layer and an image/background layer. The two layers are then compressed using different compression schemes—currently the mask layer is compressed using TIFF-G4 compression techniques, whereas the image layer is compressed using JPEG compression techniques.
However, the MRC format may still not be sufficient in certain markets where there is a very stringent requirement or limitation for file size of scanned images. Currently, several different compression quality modes are offered that produce different levels of image quality, and therefore file sizes. However, a user does not have an easy way maximize or optimize the image quality with respect to an imposed file size requirement or constraint. This often results in the frustrating experience of a user having to try different compression settings to arrive at a decision that trades off file size limitations for image quality and vice versa.
The present invention is directed to a system and/or which enables a, operational “mode” whereby a system administrator could set a maximum limit on any exported file size from an image input terminal such as a walk-up scanner. In response to the limit, the scanning device, or an associated image processor, dynamically changes the parameters needed to segment a scanned image into layers for exporting in accordance with the MRC model, so that final exported file size remains within the specified limit. Such a system, it is believed, will result in increased user satisfaction by eliminating the need for iterative selection of scanning/compression modes.
In accordance with the present invention, there is provided an image input system, comprising: an image input device suitable for generating data representing a color digital image; memory, connected to the image input device for storing the data representing the a color digital image; and an image processor, for retrieving from said memory data representing the color digital image, said image processor operating in response to a pre-programmed set of instructions to process the data representing the image and generate an image file in accordance with a predefined format, wherein the image processor dynamically controls the size of the image file in response to a predefined requirement.
In accordance with another aspect of the present invention, there is provided a method for dynamically controlling the file size of a color digital image, comprising the steps of: (a) receiving uncompressed color digital image data; (b) using the digital image data, segmenting the digital image to identify segments of the image, including identification of a first set of segments of the image suitable for representation as a single color and a second set of segments suitable for representation as contone; (c) estimating the size of the compressed image based upon said segmenting step, wherein at least first set of segments are to be compressed in accordance with a first method applicable to single color segments to create a first image plane and the second set of segments are to be compressed in accordance with a second method applicable to contone segments to create a second image plane; (d) determine whether an estimated size of the compressed image is within a predefined file size limit; and if so, proceeding at step (f), otherwise (d) identifying at least one segment within the second set of segments for representation as a single color and for incorporation into said first set of segments and said first image plane; (e) repeating the steps above, beginning at step (c); (f) creating the first image plane based upon image data for the first set of segments and creating the second image plane based upon image data for the first set of segments, wherein at least the second image plane is compressed; and (g) outputting the data for the first and second image planes.
One aspect of the invention is based on the discovery that a user is often willing to compromise on the color fidelity of some portions of a scanned document in order to reduce files size of the document, and that it is possible to iteratively estimate the size of a scanned document using an MRC image format. This discovery avoids problems that arise in using multifunction devices such as walk-up scanner/copiers and scan-to-export features on such systems—eliminating the need for the user to “manually” adjust image quality to achieve desired output file size. Using the techniques set forth herein, the present invention is able to produce a representation of an image in a modified (two-layer) MRC format that is suitable for network transmission and storage on local or networked devices. Accordingly, the present invention enables, through the use of image segmentation and compression, the dynamic adjustment of a scanned image in order to automatically achieve or stay within a file size limitations, but does so in a manner that selectively maximizes the color fidelity of the scanned image. As a result of the techniques employed in accordance with the present invention, users of scanners and multifunction devices, and scan-to-export features of such systems, will be able to automatically optimize the quality of the scanned images while meeting any self or network imposed file size limitations.
The present invention will be described in connection with a preferred embodiment, however, it will be understood that there is no intent to limit the invention to the embodiment described. On the contrary, the intent is to cover all alternatives, modifications, and equivalents as may be included within the spirit and scope of the invention as defined by the appended claims.